<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>


<script type="text/javascript">

    var arr = [];

    for(var i = 0 ;i < 4 ;i++)
            arr[i] = i;

    for(var i = 0 ;i< 4 ; i++)
        console.log(arr[0])

    console.log(arr[3])
</script>
</body>
</html>